home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 1996 #1 / Amiga Plus CD - 1996 - No. 1.iso / pd / netz / xbtx_v1.1 / attributes.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-09-26  |  3.3 KB  |  74 lines

  1. /*
  2.  * Copyright (c) 1992, 1993 Arno Augustin, Frank Hoering, University of
  3.  * Erlangen-Nuremberg, Germany.
  4.  * All rights reserved.
  5.  *
  6.  * Redistribution and use in source and binary forms, with or without
  7.  * modification, are permitted provided that the following conditions
  8.  * are met:
  9.  * 1. Redistributions of source code must retain the above copyright
  10.  *    notice, this list of conditions and the following disclaimer.
  11.  * 2. Redistributions in binary form must reproduce the above copyright
  12.  *    notice, this list of conditions and the following disclaimer in the
  13.  *    documentation and/or other materials provided with the distribution.
  14.  * 3. All advertising materials mentioning features or use of this software
  15.  *    must display the following acknowledgement:
  16.  *    This product includes software developed by the University of
  17.  *    Erlangen-Nuremberg, Germany.
  18.  * 4. Neither the name of the University nor the names of its contributors
  19.  *    may be used to endorse or promote products derived from this software
  20.  *    without specific prior written permission.
  21.  *
  22.  * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR
  23.  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  24.  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  IN NO
  25.  * EVENT SHALL THE AUTHORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  26.  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
  27.  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
  28.  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
  29.  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  30.  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
  31.  * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  32.  *
  33.  * This software has not been validated by the ``Bundesamt fuer Zulassungen in
  34.  * der Telekommunikation'' of the ``Deutsche Bundepost Telekom'' and thus
  35.  * must not be used for accessing the BTX-Network of the Telekom in Germany.
  36.  *
  37.  * Diese Software hat keine Zulassung durch das Bundesamt fuer Zulassungen in
  38.  * der Telekommunikation der Deutschen Bundespost Telekom und darf daher nicht
  39.  * am Netz der Deutschen Bundespost Telekom in Deutschland betrieben werden.
  40.  */
  41.  
  42. #define ATTR_UNDERLINE  0x00001
  43. #define ATTR_FLASH      0x00002
  44. #define ATTR_INVERTED   0x00008
  45. #define ATTR_WINDOW     0x00010
  46. #define ATTR_PROTECTED  0x00020
  47. #define ATTR_MARKED     0x00040
  48. #define ATTR_CONCEALED  0x00080
  49. #define ATTR_YDOUBLE    0x00100
  50. #define ATTR_XDOUBLE    0x00200
  51.  
  52. #define ATTR_FOREGROUND 0x00400  /* only for set_attr() !! */
  53. #define ATTR_BACKGROUND 0x00800  /*  "  */
  54. #define ATTR_NODOUBLE   0x01000  /*  "  */
  55. #define ATTR_XYDOUBLE   0x02000  /*  "  */
  56. #define ATTR_SIZE       0x04000
  57. #define ATTR_ANYSIZE    (ATTR_NODOUBLE|ATTR_XDOUBLE|ATTR_YDOUBLE|ATTR_XYDOUBLE)
  58.  
  59.  
  60. #define attrib(y,x,a)    ((screen[(y)-1][(x)-1].attr & (a)) > 0)
  61. #define realattr(y,x,a)  ((screen[(y)-1][(x)-1].real & (a)) > 0)
  62. #define attr_fg(y,x)     screen[(y)-1][(x)-1].fg
  63. #define attr_bg(y,x)     screen[(y)-1][(x)-1].bg
  64.  
  65. #define BLACK        0
  66. #define RED          1
  67. #define GREEN        2
  68. #define YELLOW       3
  69. #define BLUE         4
  70. #define MAGENTA      5
  71. #define CYAN         6
  72. #define WHITE        7
  73. #define TRANSPARENT  8
  74.